<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<meta name="viewport" content="width=device-width, initial-scale=1">
	<title>配置节点</title>
    <link rel="icon" href="favicon.ico">
	<link rel="stylesheet" href="css/bootstrap.min.css">
    <link rel="stylesheet" href="css/bootstrap-theme.min.css">
	<style>
		body {
			padding-top: 70px;
		}
        .setting-form {
			max-width: 800px;
			margin: 0 auto;
		}
		.form-btn-group div {
			padding: 20px;
		}
    </style>
</head>
<body>

<div role="main">

	<form class="form-horizontal setting-form" role="form">
	   <div class="form-group">
		  <label for="myid" class="col-sm-2 control-label">ID:</label>
		  <div class="col-sm-10">
			 <input type="text" class="form-control" id="myid" placeholder="Enter ID" value="1234567">
		  </div>
	   </div>
	   <div class="form-group">
		  <label for="myname" class="col-sm-2 control-label">Name:</label>
		  <div class="col-sm-10">
			 <input type="text" class="form-control" id="myname" placeholder="Enter Name" value="八佰伴高档葡萄酒货架003">
		  </div>
	   </div>
	   <div class="form-group">
		  <label for="mycontent" class="col-sm-2 control-label">Content:</label>
		  <div class="col-sm-10">
			<textarea cols="40" rows="12" class="form-control" id="mycontent"></textarea>
		  </div>
	   </div>
	   <div class="form-group">
		  <div class="col-sm-offset-2 col-sm-10">
			 <button type="button" id="btn-save" class="btn btn-default">Submit</button>
			 <button type="button" id="btn-cancel" class="btn btn-default">Cancel</button>
		  </div>
	   </div>
	</form>

</div><!-- /main -->

</body>
<script src="js/jquery.js"></script>
<script src="js/bootstrap.min.js"></script>
<script>
$("#btn-save").click(function(){
	$.get("save.json", $(".setting-form").serialize(), function(data){
		alert("保存成功!");
	});
});
$("#btn-cancel").click(function(){
	history.back();
});
</script>
</html>
